<?php
global $_RQ,$_AR;
$_RQ['op']=$_RQ['op']?$_RQ['op']:'list';
$return=array();
cfc('core')->checklogin();
if($_RQ['op']=='list'){
	$pindex = max(1, intval($_SESSION['page']));
	$psize = 15;
	
	$params=array('uniacid'=>$_SESSION['uniacid'],'mid'=>$_SESSION['uid']);	
    //$fields=array('id','ordersn','name','mobile','driver_id','mid','createtime','status','price','price1','start_seat','dest_seat','cuid');
    $orderby='createtime desc';
	$total='';
	$return['list']=pdo_getslice('jy_smallquan_manager_order',$params,array($pindex,$psize),$total,$fields,'',$orderby);	
	print_r($return['list']);exit();
	if($return['list']){
		foreach($return['list'] as &$v){
			$member=pdo_get('core_members',array('id'=>$v['managerid']),array('mobile','realname'));
			$v['realname']=$member['realname'];
			$v['mobile']=$member['mobile'];
			$v['createtime']=date('Y-m-d H:i:s',$v['createtime']);
		}
	}
	$return['type']=array('1'=>'送水','2'=>'维修','3'=>'帮忙');
	$return['status']=array('0'=>'待服务','1'=>'正在处理','2'=>'已完成');
	exi($return);
	
	}
	